<?php
declare (strict_types=1);

namespace app\user\service\user;

use app\common\service\BaseService;
use app\user\logic\user\Face as FaceLogic;
use app\user\logic\user\FaceVerify;
use think\{annotation\Inject, Request};

/**
 * 用户个人中心接口类
 */
class Face extends BaseService
{

    /**
     * @Inject()
     *
     * @var FaceLogic
     */
    private $faceLogic;

    // /**
    //  * 获取人员库信息
    //  */
    // public function getGroupInfo(Request $request)
    // {
    //     $param = $request->get();
    //     $re = app(FaceLogic::class)->getGroupInfo($param);
    //
    //     return $this->parseToData($re, 1, '获取成功');
    // }

    /**
     * 创建人员
     */
    public function createPerson(Request $request)
    {
        $this->faceLogic->createPerson($request);

        return $this->parseToData([], 1, '绑定成功');
    }

    /**
     * 验证人员
     */
    public function verifyPerson(Request $request)
    {
        $this->faceLogic->verifyPerson($request);

        return $this->parseToData([], 1, '验证通过');
    }

    /**
     * 删除人员
     */
    public function deletePerson(Request $request)
    {
        $this->faceLogic->deletePerson($request);

        return $this->parseToData([], 1, '解绑成功');
    }

}
